package com.project.zsxd.server.common.util;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

public class LogUtil {

    private static final Logger LOG = LoggerFactory.getLogger(LogUtil.class);

    public static void debug(String s) {
        if (LOG.isDebugEnabled()) {
            LOG.debug(s);
        }
    }

    public static void debug(String s, Object... objects) {
        if (LOG.isDebugEnabled()) {
            LOG.debug(s, objects);
        }
    }

    public static void warn(String s) {
        if (LOG.isWarnEnabled()) {
            LOG.warn(s);
        }
    }

    public static void warn(String s, Object... objects) {
        if (LOG.isWarnEnabled()) {
            LOG.warn(s, objects);
        }
    }

    public static void info(String s) {
        if (LOG.isInfoEnabled()) {
            LOG.info(s);
        }
    }

    public static void info(String s, Object... objects) {
        if (LOG.isInfoEnabled()) {
            LOG.info(s, objects);
        }
    }

    public static void error(String s) {
        if (LOG.isErrorEnabled()) {
            LOG.error(s);
        }
    }

    public static void error(String s, Object... objects) {
        if (LOG.isErrorEnabled()) {
            LOG.error(s, objects);
        }
    }

    public static void error(String s, Throwable throwable) {
        if (LOG.isErrorEnabled()) {
            LOG.error(s, throwable);
        }
    }

}
